﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using Ranet.AgOlap.Controls.KpiChoice;
using Galaktika.BI.Runtime.Services;

namespace Galaktika.BI.Silverlight.Controls.KpiChoice
{
    public class KpiChoiceControlEx : KpiChoiceCtrl
    {
        public KpiChoiceControlEx()
            : base()
        { 
        
        }

        IBindingContext m_Context = null;
        public IBindingContext Context 
        { 
            get{
                return m_Context;
            }
            set {
                m_Context = value;
                KPILoaderEx loader = Loader as KPILoaderEx;
                if (loader != null)
                {
                    loader.Context = value;
                }
            } 
        }

        protected override Ranet.AgOlap.Controls.General.IDataLoader GetDataLoader()
        {
            return new KPILoaderEx();
        }
    }
}
